<template>
    <div class="header">
        <i @click="back" class="fa fa-angle-left"></i>
        <div class="title">
            <slot></slot>
        </div>
    </div>
</template>

<script>
    export default {
        data(){
            return{

            }
        },
        methods:{
            back(){
                //后退
                window.history.back()
            }
        }
    }
</script>

<style scoped>
    .header{
        /*position: fixed;*/
        width: 100%;
        height: 8.2rem;
        background-color: #BCB46B;
        font-size: 16px;
        top: 0;
        z-index: 1000;
        left: 0;
    }
    .header i{
        /*position: absolute;*/
        color: white;
        margin-left: 1rem;
        font-size: 2rem;
    }
    .header .title{
        color: #ddd;
     
    }
</style>